home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1996 June / EnigmA AMIGA RUN 08 (1996)(G.R. Edizioni)(IT)[!][issue 1996-06][EARSAN CD VII].iso / earcd / amos / eaissu3b.lha / Source_Code / AK_Decrypter_2.AMOS / AK_Decrypter_2.amosSourceCode
AMOS Source Code  |  1995-12-30  |  2KB  |  61 lines

  1. ' Program Encrypter. 
  2. '
  3. ' Written by Andrew "Mushroom" Kellett (C) Mushroom PD.
  4. '
  5. ' This encrypter will encrypt the following letters and symbols :
  6. '
  7. ' ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789 
  8. ' '~!"�$%^&*()_-+=\|/?.>,<[]{}       91 symbols
  9. ' Any other symbol found will be ignored, but may be messed up when Encrypted. 
  10. '
  11.  
  12. Dim T1(921)
  13.  
  14. Screen Open 0,640,50,4,Hires : Paper 0 : Cls : Curs Off : Flash Off 
  15. Centre "MPD File encrypter program V2" : Print 
  16. Centre "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~" : Print : Print 
  17.  
  18. DAT1:
  19. Data 124,41,62,55,61,60,126,122,88,51,113,121,103,72,89,48,57,110
  20. Data 111,104,116,106,85,47,81,112,38,71,108,92,54,107,119,56,46
  21. Data 43,117,39,50,163,101,98,40,95,123,34,67,37,97,33,93,68,66
  22. Data 109,52,83,65,45,90,78,69,73,125,49,70,80,100,94,118,36,82
  23. Data 102,79,114,86,63,105,42,76,84,99,120,115,91,44,74,77,53,87
  24. Data 75,32
  25.  
  26. Restore DAT1 : For N=1 To 91 : Read T1(N) : Next N
  27.  
  28. 'F$=Fsel$("","","Select SOURCE file")
  29. F$="ASCII:Alan.enc"
  30.  
  31. If F$="" Then Edit 
  32.  
  33. 'G$=Fsel$("","","Select DEST file")
  34. G$="ASCII:Alan.Enc2"
  35.  
  36. Open In 1,F$ : Reserve As Data 10,Lof(1) : Reserve As Data 11,Lof(1) : Close 
  37. Bload F$,10 : LE=0 : LE2=Length(10) : MPD=Execall(-132)
  38.  
  39. J$=" ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'~!"+Chr$(34)+"�$%^&*()_-+=\|/?.>,<[]{}"
  40.  
  41. Repeat 
  42.    Centre "Bytes to go :"+Str$(LE2)+" "
  43.    P=Peek(Start(10)+LE) : CHAR=-1
  44.    
  45.    For N=1 To 91
  46.       If P=T1(N)
  47.          CHAR=Asc(Mid$(J$,N,1)) : Goto NXT
  48.       End If 
  49.    Next N
  50.    
  51.    NXT:
  52.    
  53.    If CHAR=-1
  54.       CHAR=P
  55.    End If 
  56.    
  57.    Poke Start(11)+LE,CHAR : Dec LE2 : Inc LE
  58. Until LE2=0
  59.  
  60. MPD=Execall(-138) : Wait Vbl 
  61. Bsave G$,Start(11) To Start(11)+Length(11)